package com.dubbo.impl;

import java.util.List;

import javax.annotation.Resource;
import org.springframework.stereotype.Service;

import com.dubbo.dao.UserDao;
import com.dubbo.entity.User;
import com.dubbo.inter.ServiceDemo;

/**
 * Service接口的实现类(整合mvc,mybatis和dubbo)
 * @author wyw
 * @date 2018年7月9日
 */
@Service
 public class ServiceImpl implements ServiceDemo{
    
    @Resource
    private UserDao userdao ;
    
    @Override
    public String sayHello(String name) {
         return "欢迎你,"+name ;
    }

    @Override
    public List<User> getUser(String username) {
         return userdao.findByUsername(username);
    }
   
}
